package com.web.cms.doc.message;

import java.io.Serializable;
import java.util.Date;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Null;
import javax.validation.constraints.Size;

import javax.validation.constraints.NotBlank;

import com.blue.core.dict.State;
import com.blue.validation.group.SaveModel;
import com.blue.validation.group.UpdateModel;

public class WebRequest implements Serializable
{
	private static final long serialVersionUID = 1L;

	@NotNull(groups={UpdateModel.class}, message="网站ID不能为空")
	@Null(groups={SaveModel.class}, message="网站ID必须为空")
	private Integer id;
	@NotBlank(groups={SaveModel.class}, message="网站标识不能为空")
	@Size(min=0, max=20, groups={SaveModel.class, UpdateModel.class}, message="网站标识长度[0-20]")
	private String code;
	@NotBlank(groups={SaveModel.class, UpdateModel.class}, message="网站名称不能为空")
	@Size(min=0, max=50, groups={SaveModel.class, UpdateModel.class}, message="网站名称长度[0-50]")
	private String name;
	@NotBlank(groups={SaveModel.class}, message="网站域名不能为空")
	@Size(min=0, max=100, groups={SaveModel.class, UpdateModel.class}, message="网站域名长度[0-100]")
	private String domain;
	@Size(min=0, max=200, groups={SaveModel.class, UpdateModel.class}, message="网站描述长度[0-200]")
	private String descp;
	private Date createTime;
	private State state;
	private Integer channels;
	private Integer docs;
	private Integer files;
	private Integer fileSize;

	public WebRequest()
	{
	}

	public Integer getId()
	{
		return id;
	}

	public void setId(Integer id)
	{
		this.id = id;
	}

	public String getCode()
	{
		return code;
	}

	public void setCode(String code)
	{
		this.code = code;
	}

	public String getName()
	{
		return name;
	}

	public void setName(String name)
	{
		this.name = name;
	}

	public String getDomain()
	{
		return domain;
	}

	public void setDomain(String domain)
	{
		this.domain = domain;
	}

	public String getDescp()
	{
		return descp;
	}

	public void setDescp(String descp)
	{
		this.descp = descp;
	}

	public Date getCreateTime()
	{
		return createTime;
	}

	public void setCreateTime(Date createTime)
	{
		this.createTime = createTime;
	}

	public State getState()
	{
		return state;
	}

	public void setState(State state)
	{
		this.state = state;
	}

	public Integer getChannels()
	{
		return channels;
	}

	public void setChannels(Integer channels)
	{
		this.channels = channels;
	}

	public Integer getDocs()
	{
		return docs;
	}

	public void setDocs(Integer docs)
	{
		this.docs = docs;
	}

	public Integer getFiles()
	{
		return files;
	}

	public void setFiles(Integer files)
	{
		this.files = files;
	}

	public Integer getFileSize()
	{
		return fileSize;
	}

	public void setFileSize(Integer fileSize)
	{
		this.fileSize = fileSize;
	}

}
